import request from '@/utils/request'

// 查询档案  列表 
export function listFileA(data) {
    return request({
        url: '/system/RecordManage/list',
        method: 'post',
        data: data
    })
}

// 查询档案  馆藏 
export function listFileBook(data) {
  return request({
      url: '/system/RecordManage/listbook',
      method: 'post',
      data: data
  })
}

// 借阅记录档案查询  列表
export function listFileBro(data) {
  return request({
      url: '/system/RecordManage/listBro',
      method: 'post',
      data: data
  })
}

// 查询档案  详细
export function getFileA(id, query) {
    return request({
        url: '/system/RecordManage/' + id,
        method: 'get',
        params: query
    })
}

// 新增档案  
export function addFileA(data) {
    return request({
        url: '/system/RecordManage/add',
        method: 'post',
        data: data
    })
}

// 修改档案  
export function updateFileA(data) {
    return request({
        url: '/system/RecordManage/edit',
        method: 'post',
        data: data
    })
}
// 修改档案  批量上传
export function multFile(data) {
  return request({
      url: '/system/RecordManage/multFile',
      method: 'post',
      data: data
  })
}
// 删除档案  
export function delFileA(ids, query) {
  return request({
    url: '/system/RecordManage/' + ids,
    method: 'put',
    params: query
  })
}
// 申请归档
export function updateApply(ids, query) {
    return request({
      url: '/system/RecordManage/apply/' + ids,
      method: 'put',
      params: query
    })
  }
    // 归档通过
  export function updateApprove(ids, query) {
    return request({
      url: '/system/RecordManage/approve/' + ids,
      method: 'put',
      params: query
    })
  }
  // 归档拒绝
  export function updateReject(ids, query) {
    return request({
      url: '/system/RecordManage/reject/' + ids,
      method: 'put',
      params: query
    })
  }
